<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>To do!</title>
</head>
<body>


<h1> this is a to do app!</h1>

<ul>
    {% for i in all_items %}
    <li>{{ i.content }}
        <!--delete specific item with the same id -->
        <form action="/todo/deleteTodo/{{i.id}}/" method="post" style="display: inline;">
            {% csrf_token %}
            <input type="submit" value="Delete" />
        </form>
    </li>
    {% endfor %}
</ul>

<!--add new items-->
<form action="/todo/addTodo/" method="post">
    {% csrf_token %}
    <input type="text" name="content" />
    <input type="submit" value="Add" />
</form>

</body>
</html>
